<template>
  <div id="app">
    <!-- <el-button type="danger" icon="el-icon-delete"></el-button> -->
    <Header></Header>
    <router-view>
    </router-view>
    <Footer v-show="!$route.meta.isHidden"></Footer>
  </div>
</template>

<script>
import Header from '@/components/Header'
import Footer from '@/components/Footer'
// import {reqCategoryList} from './api'
export default {
 name:'App',
 //非路由组件的注册
 components:{
   Header,
   Footer
 },
 mounted(){
    //在这发请求去获取三级分类的数据，那么就只会发一次，而且一次就够了，因为数据不变
   this.$store.dispatch("getCategoryList");
 }
 }
</script>
